home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / u_man / cat3 / Tk / clipboard.z / clipboard
Encoding:
Text File  |  2002-10-03  |  6.3 KB  |  133 lines

  1.  
  2.  
  3.  
  4. TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddCCCClllleeeeaaaarrrr((((3333TTTTkkkk))))                                  TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddCCCClllleeeeaaaarrrr((((3333TTTTkkkk))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      Tk_ClipboardClear, Tk_ClipboardAppend - Manage the clipboard
  10.  
  11. SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  12.      ####iiiinnnncccclllluuuuddddeeee <<<<ttttkkkk....hhhh>>>>
  13.  
  14.      int
  15.      TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddCCCClllleeeeaaaarrrr(_i_n_t_e_r_p, _t_k_w_i_n)
  16.  
  17.      int
  18.      TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddAAAAppppppppeeeennnndddd(_i_n_t_e_r_p, _t_k_w_i_n, _t_a_r_g_e_t, _f_o_r_m_a_t, _b_u_f_f_e_r)
  19.  
  20. AAAARRRRGGGGUUUUMMMMEEEENNNNTTTTSSSS
  21.      Tcl_Interp          *_i_n_t_e_r_p (in)      Interpreter to use for reporting
  22.                                            errors.
  23.  
  24.      Tk_Window           _t_k_w_i_n   (in)      Window that determines which
  25.                                            display's clipboard to manipulate.
  26.  
  27.      Atom                _t_a_r_g_e_t  (in)      Conversion type for this clipboard
  28.                                            item;  has same meaning as _t_a_r_g_e_t
  29.                                            argument to TTTTkkkk____CCCCrrrreeeeaaaatttteeeeSSSSeeeellllHHHHaaaannnnddddlllleeeerrrr.
  30.  
  31.      Atom                _f_o_r_m_a_t  (in)      Representation to use when data is
  32.                                            retrieved;  has same meaning as
  33.                                            _f_o_r_m_a_t argument to
  34.                                            TTTTkkkk____CCCCrrrreeeeaaaatttteeeeSSSSeeeellllHHHHaaaannnnddddlllleeeerrrr.
  35.  
  36.      char                *_b_u_f_f_e_r (in)      Null terminated string containing
  37.                                            the data to be appended to the
  38.                                            clipboard.
  39.  
  40.  
  41. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  42.      These two procedures manage the clipboard for Tk.  The clipboard is
  43.      typically managed by calling TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddCCCClllleeeeaaaarrrr once, then calling
  44.      TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddAAAAppppppppeeeennnndddd to add data for any number of targets.
  45.  
  46.      TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddCCCClllleeeeaaaarrrr claims the CLIPBOARD selection and frees any data items
  47.      previously stored on the clipboard in this application. It normally
  48.      returns TCL_OK, but if an error occurs it returns TCL_ERROR and leaves an
  49.      error message in _i_n_t_e_r_p->_r_e_s_u_l_t.  TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddCCCClllleeeeaaaarrrr must be called before
  50.      a sequence of TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddAAAAppppppppeeeennnndddd calls can be issued.
  51.  
  52.      TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddAAAAppppppppeeeennnndddd appends a buffer of data to the clipboard.  The first
  53.      buffer for a given _t_a_r_g_e_t determines the _f_o_r_m_a_t for that _t_a_r_g_e_t.  Any
  54.      successive appends for that _t_a_r_g_e_t must have the same format or an error
  55.      will be returned.  TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddAAAAppppppppeeeennnndddd returns TCL_OK if the buffer is
  56.      successfully copied onto the clipboard.  If the clipboard is not
  57.      currently owned by the application, either because TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddCCCClllleeeeaaaarrrr has
  58.      not been called or because ownership of the clipboard has changed since
  59.      the last call to TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddCCCClllleeeeaaaarrrr, TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddAAAAppppppppeeeennnndddd returns TCL_ERROR
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddCCCClllleeeeaaaarrrr((((3333TTTTkkkk))))                                  TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddCCCClllleeeeaaaarrrr((((3333TTTTkkkk))))
  71.  
  72.  
  73.  
  74.      and leaves an error message in _i_n_t_e_r_p->_r_e_s_u_l_t.
  75.  
  76.      In order to guarantee atomicity, no event handling should occur between
  77.      TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddCCCClllleeeeaaaarrrr and the following TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddAAAAppppppppeeeennnndddd calls (otherwise
  78.      someone could retrieve a partially completed clipboard or claim ownership
  79.      away from this application).
  80.  
  81.      TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddCCCClllleeeeaaaarrrr may invoke callbacks, including arbitrary Tcl scripts,
  82.      as a result of losing the CLIPBOARD selection, so any calling function
  83.      should take care to be reentrant at the point TTTTkkkk____CCCClllliiiippppbbbbooooaaaarrrrddddCCCClllleeeeaaaarrrr is
  84.      invoked.
  85.  
  86.  
  87. KKKKEEEEYYYYWWWWOOOORRRRDDDDSSSS
  88.      append, clipboard, clear, format, type
  89.  
  90.  
  91.  
  92.  
  93.  
  94.  
  95.  
  96.  
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.                                                                         PPPPaaaaggggeeee 2222
  130.  
  131.  
  132.  
  133.